﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CanDoo.Core;
using CanDoo.Data;
using CanDoo.Contracts;
using CanDoo.Oil.Core.Models;
using CanDoo.Core.Data;

namespace CanDoo.Oil.Core.Contracts
{
    /// <summary>
    /// 业务契约——临时产品序列号
    /// </summary>
    public interface ISerialNumTempContract : IServiceBaseCore<SerialNumTemp>, IServiceBase<SerialNumTemp>
    {
        /// <summary>
        /// 采购入库审核时临时库中的序列号移到正式库
        /// </summary>
        /// <param name="EntityId">单据ID</param>
        /// <returns></returns>
        OperationResult PassInStore(long EntityId);

        /// <summary>
        /// 取消采购入库审核时正式库中的序列号移到临时库
        /// </summary>
        /// <param name="EntityId">单据ID</param>
        /// <returns></returns>
        OperationResult UnPassInStore(long EntityId);

        /// <summary>
        /// 采购退货单取消审核时恢复到正式库
        /// </summary>
        /// <param name="EntityId"></param>
        /// <returns></returns>
        OperationResult UnPassInBuyBack(long EntityId);

        /// <summary>
        /// 采购退货单审核时从正式库删除
        /// </summary>
        /// <param name="EntityId"></param>
        /// <returns></returns>
        OperationResult PassInBuyBack(long EntityId);


        /// <summary>
        /// 销售出库单取消审核时将状态改为等待出库审核状态
        /// </summary>
        /// <param name="EntityId"></param>
        /// <returns></returns>
        OperationResult UnPassOutStore(long EntityId);

        /// <summary>
        /// 客户退货单取消审核时将状态改为等待退货审核状态
        /// </summary>
        /// <param name="EntityId"></param>
        /// <returns></returns>
        OperationResult UnPassOutSellBack(long EntityId);
    }
}

